
public class Conditional {
	public static void main(String[] args) {
			/*
			 * 
			 * if
			 * 
			 * switch
			 * 
			 */
		
		int i =2;
		int j = 3;
		boolean bool =false;
		
//		boolean b = (i<=2);
		if(i<=2){
			//expression
			System.out.println("SUccess");
		}else{
			System.out.println("Failure");
		}
		
		
		System.out.println(calculator1('+', 2, 4));
		
		
	}
	
	public static int calculator(char symbol, int i, int j)  {
		
		int out = 0;
		
		if(symbol == '+')
		{
			out = i+j;
		} 
		else if (symbol == '-')
		{
			out = i-j;
		}
		else if (symbol == '*')
		{
			out = i*j;
		}else if (symbol == '%'){
			
		}
		return out;
		
	}
	
	
public static int calculator1(char symbol, int i, int j)  {
		
		int out = 0;
		
		switch (symbol) {
		case '+':
			out = i+j;
			
		
		case '-':
			out = i-j;
			break;

		case '*':
			out = i*j;
			break;
			
		case '%':
			out = i%j;
			break;
			
			
		default:
			System.out.println("Wrong operator");
			break;
		}
		return out;
		
	}
}
